﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Styx.Helpers;
using System.IO;
using Styx;
using Styx.Common;
using System.ComponentModel;
using DefaultValue = Styx.Helpers.DefaultValueAttribute;
using Styx.TreeSharp;

namespace BMSVMM
{
    public class CRSettingsBMSVMM : Settings
    {
        public static readonly CRSettingsBMSVMM myPrefs = new CRSettingsBMSVMM();

        public CRSettingsBMSVMM()
            : base(
                Path.Combine(Utilities.AssemblyDirectory,
                    string.Format(@"Routines/Settings/HunterBMSVMM/HunterSettingsBMSVMM-{0}-{1}.xml", StyxWoW.Me.RealmName, StyxWoW.Me.Name))
                )
        {
        }

        [Setting]
        [DefaultValue(3)]
        [Category("Hunter")]
        [DisplayName("Adds to start Aoe")]
        public int StartAoe { get; set; }

        [Setting]
        [DefaultValue(35)]
        [Category("Hunter")]
        [DisplayName("Deterrence HP %")]
        public int deterrencePercent { get; set; }

        [Setting]
        [DefaultValue(false)]
        [Category("Hunter")]
        [DisplayName("Blood Fury")]
        [Description("Use Blood Fury")]
        public bool useBloodFury { get; set; }

        [Setting]
        [DefaultValue(false)]
        [Category("Hunter")]
        [DisplayName("Virmen Potions")]
        [Description("Use Virmen Potions on Bossfights")]
        public bool useVirmenPotions { get; set; }

        [Setting]
        [DefaultValue(false)]
        [Category("Hunter")]
        [DisplayName("Lifeblood")]
        [Description("Use Lifeblood on Bossfights")]
        public bool useLifeblood { get; set; }

        [Setting]
        [DefaultValue(false)]
        [Category("Hunter")]
        [DisplayName("Berserking")]
        [Description("Use Berserking")]
        public bool useBerserking { get; set; }

        [Setting]
        [DefaultValue(65)]
        [Category("Hunter")]
        [DisplayName("Arcane Shot Focus")]
        [Description("Use Arcane Shot above Focus %")]
        public int useArcaneFocus { get; set; }

        [Setting]
        [DefaultValue(75)]
        [Category("Pet")]
        [DisplayName("Mend Pet %")]
        [Description("Use Mend Pet when Pet HP below %")]
        public int useMendPet { get; set; }

        [Setting]
        [DefaultValue(1)]
        [Category("Pet")]
        [DisplayName("Call Survival Pet")]
        [Description("Call Pet to use with Survival Spec")]
        public int CallPetSV { get; set; }

        [Setting]
        [DefaultValue(false)]
        [Category("Pet")]
        [DisplayName("Auto Call Pet")]
        [Description("Auto Call Pet")]
        public bool CallPetAuto { get; set; }

        [Setting]
        [DefaultValue(1)]
        [Category("Pet")]
        [DisplayName("Call Raid Pet")]
        [Description("Call Pet to use in Raids/Instances")]
        public int CallPetRaid { get; set; }

        [Setting]
        [DefaultValue(1)]
        [Category("Pet")]
        [DisplayName("Call BG Pet")]
        [Description("Call Pet to use in Battlegrounds")]
        public int CallPetBG { get; set; }

        [Setting]
        [DefaultValue(1)]
        [Category("Pet")]
        [DisplayName("Call Beastmaster Pet")]
        [Description("Call Pet to use with Beastmaster Spec")]
        public int CallPetBM { get; set; }

        [Setting]
        [DefaultValue(1)]
        [Category("Pet")]
        [DisplayName("Call Marsksmanship Pet")]
        [Description("Call Pet to use with Marksmanship Spec")]
        public int CallPetMM { get; set; }

        [Setting]
        [DefaultValue(55)]
        [Category("Hunter")]
        [DisplayName("Healthstone HP %")]
        [Description("Use Healthstone below HP %")]
        public int useHealthstone { get; set; }

        public enum Traps
        {
            Never,
            Always,
            BossOnly
        }

        [Setting]
        [DefaultValue(Traps.Never)]
        [Category("Hunter")]
        [DisplayName("Explosive Trap")]
        [Description("Single Target Explosive Trap Use")]
        public Traps useExploTrap { get; set; }

        public enum Talent75
        {
            None,
            Blink_Strikes,
            A_Murder_of_Crows,
            Lynx_Rush
        }

        [Setting]
        [DefaultValue(Talent75.None)]
        [Category("Hunter")]
        [DisplayName("Tier 5")]
        [Description("For Blink Strikes choose None")]
        public Talent75 useTalent75 { get; set; }

        public enum Talent90
        {
            None,
            Glaive_Toss,
            Barrage,
            Powershot
        }

        [Setting]
        [DefaultValue(Talent90.None)]
        [Category("Hunter")]
        [DisplayName("Tier 6")]
        [Description("Wich talent to use")]
        public Talent90 useTalent90 { get; set; }

        public enum Talent60
        {
            None,
            Fervor,
            Dire_Beast,
            Thrill_of_the_Hunt
        }

        [Setting]
        [DefaultValue(Talent60.None)]
        [Category("Hunter")]
        [DisplayName("Tier 4")]
        [Description("Wich talent to use")]
        public Talent60 useTalent60 { get; set; }

        [Setting]
        [DefaultValue(0)]
        [Category("Hunter")]
        [DisplayName("Tier 6 Fervor %")]
        [Description("Use Fervor below Focus %")]
        public int useTalent60Focus { get; set; }

        [Setting]
        [DefaultValue(45)]
        [Category("Resting")]
        [DisplayName("Eat Food HP %")]
        [Description("Eat Food below HP %")]
        public int eatfoodPercent { get; set; }

        [Setting]
        [DefaultValue(3)]
        [Category("Hunter")]
        [DisplayName("Cooldowns Elites/Rares")]
        [Description("Use cooldowns on Elites/Rares when their Max Health Bigger than My Max health * Value (Not in Raids/Instances)")]
        public int CooldownElites { get; set; }

        [Setting]
        [DefaultValue(0)]
        [Category("Hunter")]
        [DisplayName("Disengage distance")]
        [Description("Use Disengage when target closer than Value. 0 to disable")]
        public int DisengageDistance { get; set; }


        // trinkets section
        public enum TrinketsUse
        {
            Manual,
            Below_HealthPercent,
            CrowdControlled,
            DPS_Boost

        }

        [Setting]
        [DefaultValue(TrinketsUse.Manual)]
        [Category("Trinket 1")]
        [DisplayName("Trinket 1")]
        [Description("When to use trinket 1")]
        public TrinketsUse Trinket1Use { get; set; }

        [Setting]
        [DefaultValue(65)]
        [Category("Trinket 1")]
        [DisplayName("Trinket 1 HP %")]
        [Description("Use trinket 1 below HP %")]
        public int trinket1hppercent { get; set; }

        [Setting]
        [DefaultValue(TrinketsUse.Manual)]
        [Category("Trinket 2")]
        [DisplayName("Trinket 2")]
        [Description("When to use trinket 2")]
        public TrinketsUse Trinket2Use { get; set; }

        [Setting]
        [DefaultValue(65)]
        [Category("Trinket 2")]
        [DisplayName("Trinket 2 HP %")]
        [Description("Use trinket 2 below HP %")]
        public int trinket2hppercent { get; set; }

        //movement

        [Setting]
        [DefaultValue(false)]
        [Category("Movement")]
        [DisplayName("Auto Target")]
        [Description("Auto Target")]
        public bool AutoTargeting { get; set; }

        [Setting]
        [DefaultValue(false)]
        [Category("Movement")]
        [DisplayName("Movement")]
        [Description("Movement")]
        public bool AutoMovement { get; set; }

        [Setting]
        [DefaultValue(false)]
        [Category("Movement")]
        [DisplayName("Auto Facing")]
        [Description("Auto Facing")]
        public bool AutoFacing { get; set; }

        [Setting]
        [DefaultValue(false)]
        [Category("Movement")]
        [DisplayName("Auto Take Pet's Target")]
        [Description("Auto Take Pet's Target")]
        public bool AutoPetTarget { get; set; }

        [Setting]
        [DefaultValue(false)]
        [Category("Movement")]
        [DisplayName("Allow Kiting")]
        [Description("Kite if target to close.")]
        public bool Kiting { get; set; }

        [Setting]
        [DefaultValue(false)]
        [Category("Movement in Raids, Instances, Dungeons")]
        [DisplayName("Disable Auto Move")]
        [Description("Disable Auto Movement in Raids, Instances, Dungeons")]
        public bool DisableAutoMovement { get; set; }

        [Setting]
        [DefaultValue(false)]
        [Category("Movement in Raids, Instances, Dungeons")]
        [DisplayName("Disable Auto Target")]
        [Description("Disable Auto Targeting in Raids, Instances, Dungeons")]
        public bool DisableAutoTargeting { get; set; }

        [Setting]
        [DefaultValue(false)]
        [Category("Movement in Raids, Instances, Dungeons")]
        [DisplayName("Disable Auto Facing")]
        [Description("Disable Auto Facing in Raids, Instances, Dungeons")]
        public bool DisableAutoFacing { get; set; }

        //misdirection
        public enum Misdirect
        {
            Auto,
            Manual
        }

        [Setting]
        [DefaultValue(Misdirect.Auto)]
        [Category("Hunter")]
        [DisplayName("Misdirection")]
        [Description("Misdirection")]
        public Misdirect MisdirectChoice { get; set; }

        public enum useEngiGloves
        {
            Manual,
            OnCoolDown,
            BossFights
        }

        [Setting]
        [DefaultValue(useEngiGloves.Manual)]
        [Category("Engineer Gloves")]
        [DisplayName("Use Engineer Gloves")]
        [Description("Use Engineer Gloves")]
        public useEngiGloves GlovesChoice { get; set; }

        

    }
}
